import * as React from 'react'
import './index.scss'

export interface Props {
    alertState: boolean;
    msg?: string;
    closeAlert: ()=>void;
}

const AlertBox = ({alertState, msg, closeAlert}: Props) => {
        return (
            <div className={"wrap-alert "+ (alertState?"active":"")}>
                <div className="wrap"></div>
                <div className="box-alert">
                    <p>{msg}</p>
                    <a href="javascript:void(0);" className="btn-sure" onClick={closeAlert}>Enter</a>
                </div>
            </div>
        )
}

export default AlertBox;